{include file=member.header.html}
<script>
$(function(){
	$('#deposit-recharge').submit(function(){
		if($(this).find('input[name="money"]').val()=='' || $(this).find('input[name="money"]').val() <= 0) {
			alert('{$lang.recharge_money_error}');
			return false;
		}
		if($(this).find('input[name="method"]:checked').val()=='offline' && $(this).find('input[name="bid"]').length <=0) {
			alert('{$lang.recharge_bank_empty}');
			return false;
		}
	});
})
</script>
<div class="content">
    {include file=member.menu.html}
    <div id="right">
    	{include file=member.curlocal.html}
        {include file=member.submenu.html}
        <div class="wrap">
            <div class="public table deposit">
            	<div class="deposit-withdraw deposit-recharge">
                	<div class="notice-word"><p>可以通过线上或线下为自己的账户充值，线下充值需要管理员审核</p></div>
                	<form method="post" id="deposit-recharge">
                    	<div class="title clearfix">
                        	<h2 class="float-left">充值到您的预存款账户</h2>
                            <div class="float-right link">
                            	<a class="add-bank" href="{url app=bank&act=add&type=debit}">添加银行卡</a>
                            </div>
                        </div>
                		<div class="form">
                			<dl class="clearfix">
                        		<dt>充值方式：</dt>
                            	<dd class="clearfix" ectype="recharge-method">
                                	<div class="method-each clearfix">
                                    	<div class="radio float-left"><input name="method" type="radio" value="online" checked="checked" /></div>
                                        <div class="name float-left">线上充值</div>
                                    </div>
                                    
                                    <div class="method-each clearfix">
                                    	<div class="radio float-left"><input name="method" type="radio" value="offline" /></div>
                                        <div class="name float-left">线下汇款</div>
                                    </div>
                                </dd>
                        	</dl>
                            <dl class="bank-list clearfix" ectype="online">
                        		<dt>充值渠道：</dt>
                            	<dd>
                                	<ul class="ui-list-icons clearfix">
                                    	<input type="hidden" name="payment_code" value="alipay" />
                                    	<li class="clearfix">
											<input class="float-left" type="radio" name="defaultbank" id="alipay" value="alipay" checked="checked" />
											<label class="float-left  icon-box current " for="alipay" >
												<span class="icon-cashier icon-cashier-alipay" title="{$lang.alipay}">&nbsp;</span>
											</label>
										</li>
                                    </ul>
                                    <ul class="ui-list-icons clearfix" style="display:none"><!--支付宝下架网银支付接口，暂时屏蔽网银选项-->
                                  		<!--{foreach from=$alipaybank item=bank key=key name=fe_bank}-->
										<li class="clearfix">
											<input class="float-left"  type="radio" name="defaultbank" id="{$key}" value="{$key}" />
											<label class="float-left icon-box current " for="{$key}" >
												<span class="icon-cashier icon-cashier-{$key}" title="{$bank}">&nbsp;<em class="qiye hidden">企业</em></span>
											</label>
										</li>
                                        <!--{/foreach}-->
                          			</ul>
                                </dd>  
                        	</dl>
                            <dl class="clearfix" ectype="offline" style="display:none">
                        		<dt>汇款银行：</dt>
                            	<dd class="clearfix">
                                	<!--{foreach from=$bank_list item=bank name=fe_bank}-->
                                	<div class="bank-each clearfix {if $smarty.foreach.fe_bank.first} selected {/if}">
                                    	<div class="radio float-left"><input name="bid" type="radio" value="{$bank.bid}" {if $smarty.foreach.fe_bank.first} checked="checked" {/if}/></div>
                                        <div class="bank-name float-left">{$bank.bank_name}</div>
                                        <div class="bank-num float-left">{$bank.num}</div>
                                        <div class="action float-right">
                                        	<a href="{url app=bank&act=edit&bid=$bank.bid}">{$lang.edit}</a>
                                        </div>
                                    </div>
                                    <!--{foreachelse}-->
									<div class="notice-word"><p>您还没有设置银行信息，请先<a href="{url app=bank&act=add&type=debit}">添加银行卡</a></p></div>
                                    <!--{/foreach}-->
                                </dd>
                        	</dl>
                            
                            <dl class="clearfix">
                        		<dt>充值金额：</dt>
                            	<dd><input type="text" name="money" class="text" value="" /> 元</dd>
                        	</dl>
                            <dl class="clearfix">
                        		<dt>充值备注：</dt>
                            	<dd><textarea name="remark" class="text"></textarea></dd>
                        	</dl>
                            <dl class="clearfix">
                        		<dt>&nbsp;</dt>
                            	<dd class="submit">
                                	<span class="btn-alipay">
                                		<input type="submit" value="下一步" />
                                    </span>
                                </dd>
                        	</dl>
                		</div>
					</form>
				</div>
            </div>
        </div>
        <div class="clear"></div>
        <div class="adorn_right1"></div>
        <div class="adorn_right2"></div>
        <div class="adorn_right3"></div>
        <div class="adorn_right4"></div>
    </div>

    <div class="clear"></div>
</div>
<iframe id='iframe_post' name="iframe_post" src="about:blank" frameborder="0" width="0" height="0"></iframe>
{include file=footer.html}
